@mixin fz-m($fontSize: 16px) {
    font-family: PingFangSC-Medium, 'PingFang SC';
    font-size: $fontSize;
    font-weight: 500;
}

@mixin fz-r($fontSize: 14px) {
    font-family: PingFangSC-Regular, 'PingFang SC';
    font-size: $fontSize;
    font-weight: 400;
}

.activity-phone-title {
    position: absolute;
    z-index: 5; // 不能低于奖品icon层级
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    box-sizing: border-box;
    width: 100%;
    height: 44px;
    padding: 0 11px;
    transform: scale(1.01); // 这里放大一点是处理有细小的空隙，原因是外部样机缩放带来的影响
    text-align: center;
    color: #000;
    background-color: #fff;

    @include fz-m;

    strong {
        flex: 1;
        margin-left: -14px;
    }
}

.activity-phone-top {
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    box-sizing: border-box;
    height: 140px;
    padding-top: 20px;
    background-image: url('//static.scrm.keyid.cn/assets/images/web-pc/bg01.png');
    background-size: 100% auto;

    .top-user-info {
        display: flex;
        align-items: center;
        padding-left: 16px;
        color: #fff;

        @include fz-m;

        .el-image {
            width: 56px;
            height: 56px;
            margin-right: 10px;
            border-radius: 50%;
        }
    }

    .top-rule-anchor {
        padding: 5px 10px;
        color: #fff;
        border-radius: 50px 0 0 50px;
        background-color: rgb(0 0 0 / 20%);

        @include fz-r;
    }
}

// 活动主体内容
.activity-phone-main-body {
    position: relative;
    z-index: 2;
    margin-top: -40px;
    padding: 16px 20px;
    border-radius: 40px 40px 0 0;
    background: linear-gradient(180deg, #ff562c 0%, #eb2233 100%);
    box-shadow: inset 0 6px 36px 0 #ffb1a3;
}

// 倒计时
.main-count-down {
    width: 260px;
    height: 28px;
    margin: -16px auto 0;
    text-align: center;
    border-radius: 0 0 18px 18px;
    background: linear-gradient(180deg, #ffecc8 0%, #ffe27a 25%, #ff9824 100%);
    box-shadow: inset 0 -4px 24px 0 rgb(255 255 255 / 50%);

    :deep(.el-statistic__content),
    .countdown-desc {
        color: #774a1c;
        line-height: 28px;

        @include fz-r(13px);
    }
}

// 公共卡片样式
.main-card {
    margin-top: 16px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 2px 10px 0 rgb(232 217 203 / 30%);
}

// 进度条
.main-progress {
    padding: 20px 20px 25px;
    text-align: center;

    // 标题
    .prgress-title {
        display: inline-flex;
        align-items: center;
        margin: 0 -20px;
        color: #774a1c;
        font-family: PingFangSC-Semibold, 'PingFang SC';
        font-size: 16px;
    }

    // 标题装饰
    .decorate {
        margin: 0 8px;

        &::after,
        &::before {
            display: inline-block;
            width: 3px;
            height: 16px;
            margin-left: 4px;
            content: '';
            transform: skewX(-20deg);
            border-radius: 3px;
            background: linear-gradient(180deg, #ffba67 0%, #fb2021 100%);
        }

        &::before {
            height: 10px;
        }
    }

    // 助力人数
    .help-num {
        color: #fb2021;
    }

    // 进度条
    .help-progress {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: space-between;
        height: 12px;
        margin-top: 37px;
        margin-bottom: 41px;
        border-radius: 6px;
        background: #ffe2bf;

        &::before {
            position: absolute;
            top: 0;
            left: 0;
            width: 12px;
            height: 12px;
            content: '';
            border-radius: 6px;
            background-color: #fb2021;
        }
    }

    .prize {
        position: relative;
        z-index: 2;

        .el-image {
            width: 26px;
            height: 26px;
        }

        &:first-child {
            .el-image {
                opacity: 0;
            }
        }
    }

    .help-button {
        width: 100%;
        height: 48px;
        color: #fff;
        border-radius: 24px;
        background: linear-gradient(180deg, #ff7651 0%, #ff2424 100%);
        box-shadow: 0 2px 16px 0 rgb(251 41 39 / 37%);
        font-weight: 600;

        @include fz-m(17px);
    }
}

// 奖品列表
.main-prize-list {
    padding-bottom: 11px;

    .prize-title {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 44px;
        color: #333;
        border-bottom: 1px solid #f5f5f5;

        @include fz-m;

        .el-image {
            width: 18px;
            height: 18px;
            margin-right: 10px;
        }
    }

    .prize-list {
        padding: 0 16px;
    }

    .prize-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        height: 70px;
        padding: 16px 0;
        border-bottom: 1px solid #f5f5f5;

        &:last-child {
            padding-bottom: 0;
            border-bottom: 0 none;
        }

        .el-image {
            flex: 0 0 70px;
            width: 70px;
            height: 70px;
            border-radius: 8px;
        }

        .prize-info {
            display: flex;
            flex: 1;
            flex-direction: column;
            justify-content: space-between;
            box-sizing: border-box;
            height: 100%;
            margin-left: 10px;
            padding: 6px 0;
            text-align: left;

            .zw-text-ellipsis {
                width: 110px;
            }

            .prize-stock-num {
                color: #969696;

                @include fz-r(12px);
            }

            .help-percentage {
                color: #fb2021;

                @include fz-r(12px);
            }

            .help-target {
                color: #666;

                @include fz-r(12px);
            }
        }

        .prize-operate .el-button {
            box-sizing: border-box;
            width: 80px;
            height: 30px;
            padding: 0 16px;
            color: #fff;
            border: 0 none;
            border-radius: 15px;
            background: linear-gradient(180deg, #ffcd39 0%, #ffab1a 100%);

            @include fz-r(15px);

            &.help-num-button {
                background: linear-gradient(180deg, #ff7651 0%, #ff2424 100%);
            }
        }
    }
}

.main-tabs {
    padding: 0 16px 12px;

    :deep(.el-tabs__nav) {
        display: flex;
        justify-content: space-around;
        width: 100%;
        height: 44px;
    }

    :deep(.el-tabs__item) {
        color: #333;

        @include fz-m;

        &.is-active {
            color: #fb2021;
        }
    }

    :deep(.el-tabs__active-bar) {
        background-color: #fb2021;
    }

    // 助力好友列表和中奖名单
    .help-firend-item,
    .winner-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 20px;

        &:last-of-type {
            margin-bottom: 12px;
        }
    }

    .winner-item {
        margin-bottom: 12px;

        .el-image {
            width: 36px;
            height: 36px;
        }
    }

    // 助力好友头像昵称
    .help-friend-info,
    .winner-info {
        flex: 1;
        margin-left: 16px;

        .el-image {
            margin-right: 8px;
            vertical-align: middle;
        }
    }

    .winner-info {
        margin-left: 7px;
    }

    // 助力好友时间
    .help-friend-time {
        color: #969696;

        @include fz-r(12px);
    }

    .winner-prize {
        color: #fb2021;

        @include fz-r(16px);
    }

    .nomore {
        text-align: center;
        color: #666;

        @include fz-r(12px);
    }

    :deep(.activity-info-content) {
        img,
        video {
            width: 100%;
            height: auto;
        }

        strong {
            font-weight: 700;
        }

        em {
            font-style: italic;
        }

        p {
            line-height: 1.5;
        }

        p + p {
            margin-top: 12px;
        }

        table {
            border: 1px solid #000;
            border-collapse: collapse;
        }

        table tr {
            border-bottom: 1px solid #000;
        }

        table td {
            border-right: 1px solid #000;
        }
    }
}

.main-rule {
    padding-bottom: 11px;

    .rule-title {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 44px;
        color: #333;
        border-bottom: 1px solid #f5f5f5;

        @include fz-m;

        .el-image {
            width: 18px;
            height: 18px;
            margin-right: 10px;
        }
    }

    .rule-desc {
        display: flex;
        margin-top: 12px;
        padding-right: 16px;
        text-align: left;
        line-height: 20px;

        @include fz-r;

        .rule-label {
            flex: 0 0 90px;
            text-align: center;
            color: #999;
        }

        .rule-content {
            word-break: break-all;
            color: #333;
        }
    }
}

// 滚动弹幕
.activity-phone-barrage-roll {
    position: absolute;
    z-index: 3;
    top: 17px;
    left: 30px;
    color: #fff;

    @include fz-r(12px);

    .barrage-roll-item {
        display: flex;
        align-items: center;
        margin-bottom: 4px;
        padding: 4px 6px;
        border-radius: 12px;
        background: rgb(0 0 0 / 40%);

        .barrage-roll-info {
            display: flex;
            align-items: center;

            .el-image {
                width: 18px;
                height: 18px;
                margin: 0 2px;
                border-radius: 50%;
            }

            .barrage-roll-prize {
                color: #ffe337;
            }
        }
    }
}

// 轮播弹幕
.activity-phone-barrage-loop {
    .barrage-roll-item {
        position: absolute;
        box-sizing: border-box;
        width: 175px;
    }

    .barrage-roll-item:nth-child(1) {
        transform: translateX(90px);
    }

    .barrage-roll-item:nth-child(2) {
        transform: translateX(-102px);
    }

    .barrage-roll-item:nth-child(3) {
        transform: translate(0, 38px);
    }

    .barrage-roll-item:nth-child(4) {
        transform: translate(264px, 38px);
    }

    .barrage-roll-item:nth-child(5) {
        transform: translate(90px, 74px);
    }
}
